-
Notifications
You must be signed in to change notification settings - Fork 400
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve Edge Caching Mechanism in InitializeEdgesWorker #2827
base: develop
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## develop #2827 +/- ##
=============================================
+ Coverage 56.01% 56.10% +0.09%
- Complexity 8197 8544 +347
=============================================
Files 2103 2140 +37
Lines 89017 90556 +1539
Branches 6560 6719 +159
=============================================
+ Hits 49854 50795 +941
- Misses 37445 38004 +559
- Partials 1718 1757 +39 |
@michaelgrill: Can you please take over?
@Sn0w3y: I suggest we make the refresh time configurable (time in minutes). What do you think? |
I will add a Configurable Time to the Worker aswell as "Enable and Disable" Option :) |
One value is sufficient. Negative or zero means "disable". |
Done :) |
I had a quick look and renamed the config property to |
This pull request enhances the InitializeEdgesWorker class by implementing a regular caching mechanism for edges from PostgreSQL. The main improvements are:
Regular edge caching: Edges are now cached immediately upon startup and then every 20 minutes.
Simplified scheduling: Uses a ScheduledExecutorService to manage both immediate and periodic tasks.
Executor management: Ensures that executors are properly shut down when stopping the worker.
Improved error handling and logging: Enhanced logging for better error tracing and debugging.
Benefits